package com.itany.controller;

import com.itany.pojo.Press;
import com.itany.service.PressService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Controller;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.ResponseBody;

import java.util.List;

/**
 * Author：sl
 * Date：2019-09-23 下午4:28
 * Description：<描述>
 */
@RequestMapping("/press")
@Controller
public class PressController {

    @Autowired
    private PressService pressService;

    @RequestMapping("/findAll")
    @ResponseBody
    public List<Press> findAll(){
        List<Press> all = pressService.findAll();
        return all;
    }


}
